<template>
    <div class="partbox flexrowbetween">
        <span>{{title}}</span>
        <div v-if="showback" class="backbtn" @click="back"><i class="el-icon-back"></i>返回</div>
    </div>
</template>
<script>
export default {
    data(){
        return {

        }
    },
    
    props:{
        title:{
            type: String,
            default: "",
        },
        showback:{
            type: Boolean,
            default: false,
        }
    },

    methods:{
        back(){
            this.$router.back();
        }
    }
}
</script>
<style lang="scss" scoped>
.partbox{
    width: 100%;
    // border-radius: 6px 6px 6px 6px;
    padding: 16px;
    font-size: 14px;
    background-color: #fff;
    color: #000;
    font-weight: 700;
    // background: linear-gradient(270deg, #BDDCFF 0%, #EBF5FF 100%);
}
.backbtn{
    border-radius: 6px;
    color: #000;
    background-color: white;
    text-align: center;
    width: 76px;
    height: 30px;
    line-height: 30px;
    cursor: pointer;
    i{
        display: inline-block;
        margin-right: 5px;
    }
}
</style>